# +----------------------------------------------------------------------
# | ChatWork智能聊天办公系统
# +----------------------------------------------------------------------
# | 软件声明: 本系统并非自由软件,未经授权任何形式的商业使用均属非法。
# | 版权保护: 任何企业和个人不允许对程序代码以任何形式任何目的复制/分发。
# | 授权要求: 如有商业使用需求,请务必先与版权所有者取得联系并获得正式授权。
# +----------------------------------------------------------------------
# | Author: ChatWork Team <2474369941@qq.com>
# +----------------------------------------------------------------------
class AdminConfig:
    # 安全配置项
    security = {
        # 令牌数量限制
        "token_limit": 5,
        # 令牌过期时间
        "token_timeout": 7200,
        # 令牌续签期限
        "token_renewal": 1800,
        # 支持并发登录
        "is_concurrent": True,
        # 缓存前缀名称
        "cache_prefix": "login:spi_"
    }

    # 登录验证码
    enable_captcha = True

    # 免登录验证
    not_need_login = [
        "index:config",
        "login:captcha",
        "login:check"
    ]

    # 免权限验证
    not_need_perms = [
        "login:logout",
        "attach:cate_lists",
        "attach:album_lists",
        "auth:admin:oneself",
        "auth:admin:set_info",
        "auth:role:whole",
        "auth:dept:whole",
        "auth:post:whole",
        "index:models",
        "square:category:whole",
        "content:category:whole",
        "setting:ai:secret:channel",
        "market:recharge:get_config",
        "market:subscribe:get_config"
    ]
